package com.gaogzhen.utils;

import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;

public class FileReader {
    public static void read(String filename) {
        int idx = filename.lastIndexOf(File.separator);
        String shortName = filename.substring(0, idx);
        try(FileInputStream fin = new FileInputStream(filename)) {
            long start = System.currentTimeMillis();
            byte[] buf = new byte[1024];
            int n = -1;
            while ((n = fin.read(buf)) != -1) {
            }
            long end = System.currentTimeMillis();
        } catch (IOException e) {
            e.printStackTrace();
        }

    }
}
